const Sequelize = require('sequelize');
module.exports = function(sequelize, DataTypes) {
  return sequelize.define('base_project_account', {
    projectId: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'project_id'
    },
    projectName: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'project_name'
    },
    projectType: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'project_type'
    },
    projectAddress: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'project_address'
    },
    progress: {
      type: DataTypes.STRING(800),
      allowNull: true
    },
    county: {
      type: DataTypes.STRING(255),
      allowNull: true
    },
    userId: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'user_id'
    },
    manager: {
      type: DataTypes.STRING(255),
      allowNull: true
    },
    managerPhone: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'manager_phone'
    },
    placeCode: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'place_code'
    },
    isCityProject: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'is_city_project'
    },
    isStop: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'is_stop'
    },
    riskLevel: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'risk_level'
    },
    regulators: {
      type: DataTypes.STRING(255),
      allowNull: true
    },
    remarks: {
      type: DataTypes.STRING(255),
      allowNull: true
    },
    isDeleted: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'is_deleted'
    },
    createdUser: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'created_user'
    },
    createdTime: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'created_time'
    },
    updatedUser: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'updated_user'
    },
    updatedTime: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'updated_time'
    },
    groupId: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'group_id'
    },
    schemeSystemFile: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'scheme_system_file'
    },
    investedFunds: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'invested_funds'
    },
    isNewQuote: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'is_new_quote'
    },
    isQuoteIntelligence: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'is_quote_intelligence'
    },
    isPilotProject: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'is_pilot_project'
    },
    emergencyPlan: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'emergency_plan'
    },
    isGovernmentProject: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'is_government_project'
    },
    isPerformProgram: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'is_perform_program'
    },
    isPurchaseInsurance: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'is_purchase_insurance'
    },
    premium: {
      type: DataTypes.STRING(255),
      allowNull: true
    },
    insuranceAmount: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'insurance_amount'
    },
    isConstructionPermit: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'is_construction_permit'
    },
    reservePlanBackups: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'reserve_plan_backups'
    },
    insuranceContract: {
      type: DataTypes.STRING(255),
      allowNull: true,
      field: 'insurance_contract'
    },
    account: {
      type: DataTypes.STRING(255),
      allowNull: true
    }
  }, {
    sequelize,
    tableName: 'base_project_account',
    timestamps: false
  });
};
